const toDateString = timestamp => { //转日期格式
    if(!timestamp) return;
    return new Date(timestamp).format('yyyy-MM-dd');
}

const toTimeString = timestamp => { //转日期时间格式
    if (!timestamp) return;
    return new Date(timestamp).format('yyyy-MM-dd hh:mm:ss');
}

const toGenderString = str =>{
    return  str === "3" ? "未知" : (str === "1" ? "男" : "女");
}

export {
    toDateString,
    toTimeString,
    toGenderString
}